﻿<ResourceDictionary 
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:sys="clr-namespace:System;assembly=mscorlib"
    xmlns:v="clr-namespace:ShredTheLog.Views;assembly=ShredTheLog.Views"
    xmlns:vm="clr-namespace:ShredTheLog.ViewModels;assembly=ShredTheLog.ViewModels"
    xmlns:cnv="clr-namespace:ShredTheLog.Converters;assembly=ShredTheLog.Converters"
    xmlns:c="clr-namespace:ShredTheLog.Controls;assembly=ShredTheLog.Controls"
    >

    <ResourceDictionary.MergedDictionaries>
        <ResourceDictionary Source="pack://application:,,,/ShredTheLog.Themes;component/AppIcon.xaml"/>
    </ResourceDictionary.MergedDictionaries>

    <Style x:Key="WindowBaseStyle" TargetType="{x:Type Window}">
        <Setter Property="Icon" Value="{StaticResource AppIcon}"/>
    </Style>

    <Style TargetType="{x:Type v:MainView}" BasedOn="{StaticResource WindowBaseStyle}">
        <Setter Property="Width" Value="350"/>
        <Setter Property="Height" Value="700"/>
        <Setter Property="MinWidth" Value="350"/>
        <Setter Property="MinHeight" Value="400"/>
        <Setter Property="Title" Value="{c:LocalizedString s_AppTitle}"/>
    </Style>

    <Style TargetType="{x:Type v:UserProfileView}" BasedOn="{StaticResource WindowBaseStyle}">
        <Setter Property="Width" Value="550"/>
        <Setter Property="Height" Value="300"/>
        <Setter Property="MinWidth" Value="550"/>
        <Setter Property="MinHeight" Value="300"/>
        <Setter Property="Title" Value="{Binding Path=Name, StringFormat={c:LocalizedString s_Profile}}"/>
    </Style>

    <Style TargetType="{x:Type v:TextChatRoomView}" BasedOn="{StaticResource WindowBaseStyle}">
        <Setter Property="Width" Value="600"/>
        <Setter Property="Height" Value="400"/>
        <Setter Property="MinWidth" Value="600"/>
        <Setter Property="MinHeight" Value="400"/>
        <Setter Property="Title" Value="{Binding Path=RoomName, Mode=OneWay, Converter={x:Static cnv:RoomConverter.Default}}"/>
    </Style>

    <Style TargetType="{x:Type v:AboutView}" BasedOn="{StaticResource WindowBaseStyle}">
        <Setter Property="ResizeMode" Value="NoResize"/>
        <Setter Property="SizeToContent" Value="WidthAndHeight"/>
        <Setter Property="Title" Value="{Binding Path=Product, StringFormat={c:LocalizedString s_AboutDialogTitle}}"/>
    </Style>

    <Style TargetType="{x:Type v:LogInView}" BasedOn="{StaticResource WindowBaseStyle}">
        <Setter Property="Width" Value="300"/>
        <Setter Property="Height" Value="150"/>
        <Setter Property="MinWidth" Value="300"/>
        <Setter Property="MinHeight" Value="150"/>
        <Setter Property="ResizeMode" Value="NoResize"/>
        <Setter Property="ShowInTaskbar" Value="True"/>
        <Setter Property="SizeToContent" Value="Height"/>
        <Setter Property="Title" Value="{c:LocalizedString s_LogIn}"/>
    </Style>

    <Style TargetType="{x:Type v:SettingsView}" BasedOn="{StaticResource WindowBaseStyle}">
        <Setter Property="Width" Value="550"/>
        <Setter Property="Height" Value="400"/>
        <Setter Property="MinWidth" Value="550"/>
        <Setter Property="MinHeight" Value="400"/>
        <Setter Property="ShowInTaskbar" Value="True"/>
        <Setter Property="Title" Value="{c:LocalizedString s_Settings}"/>
    </Style>

    <Style TargetType="{x:Type v:ErrorView}" BasedOn="{StaticResource WindowBaseStyle}">
        <Setter Property="Width" Value="400"/>
        <Setter Property="MinWidth" Value="400"/>
        <Setter Property="ShowInTaskbar" Value="True"/>
        <Setter Property="Title" Value="{c:LocalizedString s_ShredTheLogError}"/>
        <Setter Property="SizeToContent" Value="Height"/>
        <Setter Property="ResizeMode" Value="NoResize"/>
    </Style>

    <Style TargetType="{x:Type v:InputView}" BasedOn="{StaticResource WindowBaseStyle}">
        <Setter Property="Width" Value="300"/>
        <Setter Property="MinWidth" Value="300"/>
        <Setter Property="ShowInTaskbar" Value="True"/>
        <Setter Property="Title" Value="{Binding WindowTitle}"/>
        <Setter Property="SizeToContent" Value="Height"/>
        <Setter Property="ResizeMode" Value="NoResize"/>
    </Style>

    <Style TargetType="{x:Type v:MessageDialogView}" BasedOn="{StaticResource WindowBaseStyle}">
        <Setter Property="Width" Value="300"/>
        <Setter Property="MinWidth" Value="300"/>
        <Setter Property="Height" Value="150"/>
        <Setter Property="MinHeight" Value="150"/>
        <Setter Property="ShowInTaskbar" Value="True"/>
        <Setter Property="Title" Value="{Binding WindowTitle}"/>
    </Style>

    <Style TargetType="{x:Type v:PrivateChatRequestView}" BasedOn="{StaticResource WindowBaseStyle}">
        <Setter Property="Width" Value="300"/>
        <Setter Property="MinWidth" Value="300"/>
        <Setter Property="Height" Value="400"/>
        <Setter Property="MinHeight" Value="400"/>
        <Setter Property="ShowInTaskbar" Value="True"/>
        <Setter Property="Title" Value="{Binding Path=Caller.Name, StringFormat={c:LocalizedString s_PrivateChatRequestFrom}}"/>
    </Style>

    <Style TargetType="{x:Type v:UserSearchConditionsView}" BasedOn="{StaticResource WindowBaseStyle}">
        <Setter Property="Width" Value="400"/>
        <Setter Property="MinWidth" Value="400"/>
        <Setter Property="SizeToContent" Value="Height"/>
        <Setter Property="ResizeMode" Value="NoResize"/>
        <Setter Property="ShowInTaskbar" Value="True"/>
        <Setter Property="Title" Value="{c:LocalizedString s_Conditions_UserSearch}"/>
    </Style>

</ResourceDictionary>